<!doctype html>
<html lang="zh-Hans" dir="ltr" class="docs-wrapper docs-doc-page docs-version-current plugin-docs plugin-id-default docs-doc-id-changelog/x/2021-06-28-knife4j-2.0.9-issue">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.1">
<link rel="search" type="application/opensearchdescription+xml" title="Knife4j" href="/opensearch.xml">

<!-- Google Tag Manager -->
    <script>!function(e,t,a,n,g){e[n]=e[n]||[],e[n].push({"gtm.start":(new Date).getTime(),event:"gtm.js"});var m=t.getElementsByTagName(a)[0],r=t.createElement(a);r.async=!0,r.src="https://www.googletagmanager.com/gtm.js?id=GTM-TKBX678",m.parentNode.insertBefore(r,m)}(window,document,"script","dataLayer")</script>
    <!-- End Google Tag Manager -->
<script src="/js/custom.js"></script>
<script src="/js/baidu.js"></script>
<script src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-1589206801610969" async crossorigin="anonymous"></script><title data-rh="true">[v2.0.9-2021/06/28 Knife4j 2.0.9发布,解决issue 150+] | Knife4j</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://doc.xiaominfo.com/docs/changelog/x/2021-06-28-knife4j-2.0.9-issue"><meta data-rh="true" name="docusaurus_locale" content="zh-Hans"><meta data-rh="true" name="docsearch:language" content="zh-Hans"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="[v2.0.9-2021/06/28 Knife4j 2.0.9发布,解决issue 150+] | Knife4j"><meta data-rh="true" name="description" content="Knife4j前身是swagger-bootstrap-ui,是一个为Swagger接口文档赋能的工具"><meta data-rh="true" property="og:description" content="Knife4j前身是swagger-bootstrap-ui,是一个为Swagger接口文档赋能的工具"><link data-rh="true" rel="icon" href="/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://doc.xiaominfo.com/docs/changelog/x/2021-06-28-knife4j-2.0.9-issue"><link data-rh="true" rel="alternate" href="https://doc.xiaominfo.com/docs/changelog/x/2021-06-28-knife4j-2.0.9-issue" hreflang="zh-Hans"><link data-rh="true" rel="alternate" href="https://doc.xiaominfo.com/docs/changelog/x/2021-06-28-knife4j-2.0.9-issue" hreflang="x-default"><link data-rh="true" rel="preconnect" href="https://3CRIMRK623-dsn.algolia.net" crossorigin="anonymous"><link rel="stylesheet" href="/assets/css/styles.66359a73.css">
<link rel="preload" href="/assets/js/runtime~main.e0db172c.js" as="script">
<link rel="preload" href="/assets/js/main.c059fb6e.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function e(e){document.documentElement.setAttribute("data-theme",e)}var t=function(){var e=null;try{e=localStorage.getItem("theme")}catch(e){}return e}();null!==t?e(t):window.matchMedia("(prefers-color-scheme: dark)").matches?e("dark"):window.matchMedia("(prefers-color-scheme: light)").matches?e("light"):e("dark")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_fXgn">跳到主要内容</a></div><nav class="navbar navbar--fixed-top navbarHideable_m1mJ"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a class="navbar__brand" href="/"><div class="navbar__logo"><img src="/img/knife4j-light.svg" alt="" class="themedImage_ToTc themedImage--light_HNdA"><img src="/img/knife4j-dark.svg" alt="" class="themedImage_ToTc themedImage--dark_i4oU"></div><b class="navbar__title text--truncate">Knife4j</b></a><a class="navbar__item navbar__link" href="/docs/quick-start">文档</a><a class="navbar__item navbar__link changelog" href="/docs/middleware-sources">中间件</a><a class="navbar__item navbar__link changelog" href="/docs/oas">OAS规范</a><a class="navbar__item navbar__link changelog" href="/docs/action">实战指南</a><a aria-current="page" class="navbar__item navbar__link changelog navbar__link--active" href="/docs/changelog">更新日志</a><a class="navbar__item navbar__link changelog" href="/docs/faq">FAQ</a><div class="navbar__item dropdown dropdown--hoverable"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">旧版本</a><ul class="dropdown__menu"><li><a class="dropdown__link" target="_blank" href="/v2/index.html">2.0.9</a></li></ul></div></div><div class="navbar__items navbar__items--right"><div class="toggle_MW0i colorModeToggle_x44X"><button class="clean-btn toggleButton_yw5v toggleButtonDisabled_BJd7" type="button" disabled="" title="切换浅色/暗黑模式（当前为暗黑模式）" aria-label="切换浅色/暗黑模式（当前为暗黑模式）"><span><svg viewBox="0 0 13 12" fill="none" xmlns="http://www.w3.org/2000/svg" width="14" height="14" class="lightToggleIcon_SFTY"><g clip-path="url(#clip0_833_8168)"><path d="M6.59998 8.49999C7.98069 8.49999 9.09998 7.3807 9.09998 5.99999C9.09998 4.61928 7.98069 3.49999 6.59998 3.49999C5.21926 3.49999 4.09998 4.61928 4.09998 5.99999C4.09998 7.3807 5.21926 8.49999 6.59998 8.49999Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M6.59985 0.5V1.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M6.59985 10.5V11.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2.7099 2.11L3.4199 2.82" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9.77991 9.17999L10.4899 9.88999" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M1.09998 6H2.09998" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M11.0999 6H12.0999" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M2.7099 9.88999L3.4199 9.17999" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path><path d="M9.77991 2.82L10.4899 2.11" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"></path></g><defs><clipPath id="clip0_833_8168"><rect width="12" height="12" fill="white" transform="translate(0.599976)"></rect></clipPath></defs></svg><svg viewBox="0 0 13 12" width="14" height="14" class="darkToggleIcon_ekgs"><path d="M10.7001 6.39501C10.6215 7.24611 10.3021 8.05721 9.77927 8.7334C9.25646 9.40959 8.55189 9.92291 7.748 10.2133C6.9441 10.5036 6.07414 10.5591 5.2399 10.3731C4.40565 10.187 3.64164 9.76728 3.03726 9.1629C2.43287 8.55851 2.01312 7.7945 1.8271 6.96026C1.64108 6.12602 1.6965 5.25605 1.98688 4.45216C2.27725 3.64826 2.79056 2.94369 3.46675 2.42088C4.14294 1.89808 4.95404 1.57866 5.80515 1.50001C5.30685 2.17414 5.06707 3.00473 5.12941 3.84071C5.19175 4.6767 5.55208 5.46254 6.14485 6.05531C6.73762 6.64808 7.52346 7.0084 8.35944 7.07074C9.19542 7.13308 10.026 6.8933 10.7001 6.39501Z" stroke="currentColor" fill="transparent" stroke-linecap="round" stroke-linejoin="round"></path></svg></span></button></div><a href="https://github.com/xiaoymin/swagger-bootstrap-ui" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link icon" title="View on GitHub">GitHub<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><div class="searchBox_ZlJk"><button type="button" class="DocSearch DocSearch-Button" aria-label="搜索"><span class="DocSearch-Button-Container"><svg width="20" height="20" class="DocSearch-Search-Icon" viewBox="0 0 20 20"><path d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="DocSearch-Button-Placeholder">搜索</span></span><span class="DocSearch-Button-Keys"></span></button></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper mainWrapper_z2l0 docsWrapper_BCFX"><button aria-label="回到顶部" class="clean-btn theme-back-to-top-button backToTopButton_sjWU" type="button"></button><div class="docPage__5DB"><aside class="theme-doc-sidebar-container docSidebarContainer_b6E3"><div class="sidebar_njMd sidebarWithHideableNavbar_wUlq"><a tabindex="-1" class="sidebarLogo_isFc" href="/"><img src="/img/knife4j-light.svg" alt="" class="themedImage_ToTc themedImage--light_HNdA"><img src="/img/knife4j-dark.svg" alt="" class="themedImage_ToTc themedImage--dark_i4oU"><b>Knife4j</b></a><nav class="menu thin-scrollbar menu_SIkG"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menuHtmlItem_M9Kj menu__list-item">
<div class="sidebar_donate">
    <div class="sidebar_sponsor">
        <a target="_blank" href="https://www.apifox.com/apiskills/apifox-auto-generates-api-docs/?utm_source=pay&utm_medium=knife4jg"><img src="/images/sponsor/apifox/Apifox IDEA@3x.png">
        </a>
    </div>
    <div class="sidebar_sponsor_submit">
        <a href="/docs/community/donate">成为赞助商</a>
    </div>
<div>
</div></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist" aria-expanded="false" href="/docs/changelog">4.x版本</a><button aria-label="打开/收起侧边栏菜单「4.x版本」" type="button" class="clean-btn menu__caret"></button></div></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist menu__link--sublist-caret menu__link--active" aria-expanded="true" href="/docs/changelog/x/2021-06-28-knife4j-2.0.9-issue">2.x版本</a></div><ul style="display:block;overflow:visible;height:auto" class="menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link menu__link--active" aria-current="page" tabindex="0" href="/docs/changelog/x/2021-06-28-knife4j-2.0.9-issue">[v2.0.9-2021/06/28 Knife4j 2.0.9发布,解决issue 150+]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-11-22-knife4j-2.0.8-issue">[v2.0.8-2020/11/22 Knife4j 2.0.8发布,轻量级微服务聚合文档中间件诞生]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-11-02-knife4j-2.0.7-issue">[v2.0.7-2020/11/02 Knife4j 2.0.7发布,细节处理]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-10-26-knife4j-2.0.6-issue">[v2.0.6-2020/10/26 Knife4j 2.0.6发布,支持OpenAPI3及Auth2认证]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-09-14-knife4j-2.0.5-issue">[v2.0.5-2020/09/14 Knife4j 2.0.5发布,性能优化]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-06-28-knife4j-2.0.4-issue">[v2.0.4-2020/06/28 Knife4j 2.0.4发布,支持自定义 Host]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-05-24-knife4j-2.0.3-issue">[v2.0.3-2020/05/24 Knife4j 2.0.3发布,支持springdoc和i18n]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2020-03-08-knife4j-2.0.2-issue">[v2.0.2-2020/03/08 Knife4j 2.0.2发布,Swagger接口文档赋能工具]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2019-12-23-knife4j-2.0.1-issue">[v2.0.1-2019/12/23 Knife4j 2.0.1发布,细节处理！]</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-2 menu__list-item"><a class="menu__link" tabindex="0" href="/docs/changelog/x/2019-12-16-knife4j-2.0.0-issue">[v2.0.0-2019/12/16 Knife4j 2.0发布,涅槃重生~！]</a></li></ul></li><li class="theme-doc-sidebar-item-category theme-doc-sidebar-item-category-level-1 menu__list-item menu__list-item--collapsed"><div class="menu__list-item-collapsible"><a class="menu__link menu__link--sublist menu__link--sublist-caret" aria-expanded="false" href="/docs/changelog/x/2019-08-28-swagger-bootstrap-ui-1.9.6-issue">1.x版本</a></div></li></ul></nav><button type="button" title="收起侧边栏" aria-label="收起侧边栏" class="button button--secondary button--outline collapseSidebarButton_PEFL"><svg width="20" height="20" aria-hidden="true" class="collapseSidebarButtonIcon_kv0_"><g fill="#7a7a7a"><path d="M9.992 10.023c0 .2-.062.399-.172.547l-4.996 7.492a.982.982 0 01-.828.454H1c-.55 0-1-.453-1-1 0-.2.059-.403.168-.551l4.629-6.942L.168 3.078A.939.939 0 010 2.528c0-.548.45-.997 1-.997h2.996c.352 0 .649.18.828.45L9.82 9.472c.11.148.172.347.172.55zm0 0"></path><path d="M19.98 10.023c0 .2-.058.399-.168.547l-4.996 7.492a.987.987 0 01-.828.454h-3c-.547 0-.996-.453-.996-1 0-.2.059-.403.168-.551l4.625-6.942-4.625-6.945a.939.939 0 01-.168-.55 1 1 0 01.996-.997h3c.348 0 .649.18.828.45l4.996 7.492c.11.148.168.347.168.55zm0 0"></path></g></svg></button></div></aside><main class="docMainContainer_gTbr"><div class="container padding-top--md padding-bottom--lg"><div class="row"><div class="col docItemCol_z5aJ"><div class="docItemContainer_c0TR"><article><nav class="theme-doc-breadcrumbs breadcrumbsContainer_Z_bl" aria-label="页面路径"><ul class="breadcrumbs" itemscope="" itemtype="https://schema.org/BreadcrumbList"><li class="breadcrumbs__item"><a aria-label="主页面" class="breadcrumbs__link" href="/"><svg viewBox="0 0 24 24" class="breadcrumbHomeIcon_OVgt"><path d="M10 19v-5h4v5c0 .55.45 1 1 1h3c.55 0 1-.45 1-1v-7h1.7c.46 0 .68-.57.33-.87L12.67 3.6c-.38-.34-.96-.34-1.34 0l-8.36 7.53c-.34.3-.13.87.33.87H5v7c0 .55.45 1 1 1h3c.55 0 1-.45 1-1z" fill="currentColor"></path></svg></a></li><li class="breadcrumbs__item"><span class="breadcrumbs__link">2.x版本</span><meta itemprop="position" content="1"></li><li itemscope="" itemprop="itemListElement" itemtype="https://schema.org/ListItem" class="breadcrumbs__item breadcrumbs__item--active"><span class="breadcrumbs__link" itemprop="name">[v2.0.9-2021/06/28 Knife4j 2.0.9发布,解决issue 150+]</span><meta itemprop="position" content="2"></li></ul></nav><div class="tocCollapsible_ETCw theme-doc-toc-mobile tocMobile_ITEo"><button type="button" class="clean-btn tocCollapsibleButton_TO0P">本页总览</button></div><div class="theme-doc-markdown markdown"><h1>[v2.0.9-2021/06/28 Knife4j 2.0.9发布,解决issue 150+]</h1><p><code>Knife4j</code>前身是<code>swagger-bootstrap-ui</code>,是一个为Swagger接口文档赋能的工具</p><p><strong>文档</strong>：<a href="https://xiaoym.gitee.io/knife4j/" target="_blank" rel="noopener">https://xiaoym.gitee.io/knife4j/</a></p><p><strong>效果(旧版)</strong>：<a href="http://swagger-bootstrap-ui.xiaominfo.com/doc.html" target="_blank" rel="noopener">http://swagger-bootstrap-ui.xiaominfo.com/doc.html</a></p><p><strong>效果(2.X版)</strong>：<a href="http://knife4j.xiaominfo.com/doc.html" target="_blank" rel="noopener">http://knife4j.xiaominfo.com/doc.html</a></p><p><strong>Gitee</strong>：<a href="https://gitee.com/xiaoym/knife4j" target="_blank" rel="noopener">https://gitee.com/xiaoym/knife4j</a></p><p><strong>GitHub</strong>：<a href="https://github.com/xiaoymin/swagger-bootstrap-ui" target="_blank" rel="noopener">https://github.com/xiaoymin/swagger-bootstrap-ui</a></p><p><strong>示例</strong>：<a href="https://gitee.com/xiaoym/swagger-bootstrap-ui-demo" target="_blank" rel="noopener">https://gitee.com/xiaoym/swagger-bootstrap-ui-demo</a></p><h2 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="日志">日志<a class="hash-link" href="#日志" title="标题的直接链接">​</a></h2><h3 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="openapi3">OpenAPI3<a class="hash-link" href="#openapi3" title="标题的直接链接">​</a></h3><p>1、在OpenAPI3.0规范中针对下载请求对象显示错误的优化<a href="https://gitee.com/xiaoym/knife4j/issues/I374SP" target="_blank" rel="noopener">Gitee#I374SP</a></p><p>2、针对OpenAPI3规范中对于<code>binary</code>类型的format属性，上传组件不显示的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I34NOS" target="_blank" rel="noopener">Gitee#I34NOS</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3BRWT" target="_blank" rel="noopener">Gitee #I3BRWT</a></p><p>3、OpenAPI3.0规范中Swagger models 中的枚举显示<a href="https://gitee.com/xiaoym/knife4j/pulls/43" target="_blank" rel="noopener">PR #43</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3DP8P" target="_blank" rel="noopener">Gitee #I3DP8P</a></p><p>4、针对OpenAPI3.0规范权限拦截问题增加接口地址<a href="https://gitee.com/xiaoym/knife4j/issues/I2810R" target="_blank" rel="noopener">Gitee #I2810R</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3HSK4" target="_blank" rel="noopener">Gitee #I3HSK4</a></p><p>5、针对OpenAPI3规范支持请求参数中包含<code>$ref</code>的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I2A89C" target="_blank" rel="noopener">Gitee #I2A89C</a></p><p>6、针对OpenAPI3规范中图片预览的问题优化<a href="https://gitee.com/xiaoym/knife4j/issues/I3IUUQ" target="_blank" rel="noopener">Gitee #I3IUUQ</a></p><h3 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="聚合组件aggregation">聚合组件aggregation<a class="hash-link" href="#聚合组件aggregation" title="标题的直接链接">​</a></h3><p>1、聚合组件针对Cloud模式转发HTTP请求时，请求头重复导致转发失败的问题<a href="https://gitee.com/xiaoym/knife4j/pulls/39" target="_blank" rel="noopener">Gitee #PR39</a></p><p>2、aggregation聚合组件增加order属性，方便开发者排序设置聚合OpenAPI文档的顺序<a href="https://gitee.com/xiaoym/knife4j/issues/I27ST2" target="_blank" rel="noopener">Gitee #I27ST2</a></p><p>3、aggregation聚合组件Nacos聚合微服务文档支持Nacos用户名及密码访问OpenAPI接口<a href="https://gitee.com/xiaoym/knife4j/issues/I28IF9" target="_blank" rel="noopener">Gitee #I28IF9</a></p><p>4、聚合组件日志打印信息优化，增加<code>isDebugEnabled</code>逻辑判断,日志级别全部由<code>info</code>改为<code>debug</code>级别<a href="https://gitee.com/xiaoym/knife4j/issues/I39QPL" target="_blank" rel="noopener">Gitee #I39QPL</a></p><p>5、聚合组件响应Model不显示的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I3EMZE" target="_blank" rel="noopener">Gitee #I3EMZE</a></p><p>6、聚合组件没有正确响应接口的状态码信息<a href="https://gitee.com/xiaoym/knife4j/pulls/44" target="_blank" rel="noopener">PR #44</a></p><p>7、基于<code>Eureka/Nacos</code>注册中心的聚合组件，增加心跳检测机制(<code>30s/per</code>)，自动剔除已经下线的服务,保证聚合文档的正常访问<a href="https://gitee.com/xiaoym/knife4j/issues/I2CKQT" target="_blank" rel="noopener">Gitee #I2CKQT</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I2CDCK" target="_blank" rel="noopener">Gitee #I2CDCK</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I2KUUY" target="_blank" rel="noopener">Gitee #I2KUUY</a></p><p>8、<code>Cloud</code>模式增加心跳检测机制(<code>30s/per</code>)，自动剔除已经下线的服务,保证聚合文档的正常访问</p><p>8、聚合组件转发文件时参数丢失的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I39OXE" target="_blank" rel="noopener">Gitee #I39OXE</a></p><h3 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="常规">常规<a class="hash-link" href="#常规" title="标题的直接链接">​</a></h3><p>1、OAuth2授权<code>Content-Type</code>的异常问题<a href="https://gitee.com/xiaoym/knife4j/pulls/35" target="_blank" rel="noopener">Gitee#PR35</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I2CKHA" target="_blank" rel="noopener">Gitee#I2CKHA</a></p><p>2、OAuth2判断异常的问题<a href="https://gitee.com/xiaoym/knife4j/pulls/37" target="_blank" rel="noopener">Gitee #PR37</a></p><p>3、修复离线导出Markdown文档自定义文档为<code>undefined</code>的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I2EDI8" target="_blank" rel="noopener">Gitee#I2EDI8</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I2WCQG" target="_blank" rel="noopener">Gitee #I2WCQG</a></p><p>4、日志的打印优化<a href="https://gitee.com/xiaoym/knife4j/issues/I39QPL" target="_blank" rel="noopener">Gitee #I39QPL</a></p><p>5、微服务聚合时<code>basePath</code>不追加的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I3B5BK" target="_blank" rel="noopener">Gitee #I3B5BK</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3EEJ3" target="_blank" rel="noopener">Gitee #I3EEJ3</a></p><p>6、针对List类型示例值多出换行符的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I2D6D4" target="_blank" rel="noopener">Gitee #I2D6D4</a></p><p>7、解决Form类型上传参数时传递<code>Null</code>的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I3AHDQ" target="_blank" rel="noopener">Gitee #I3AHDQ</a></p><p>8、针对个性化配置的保存问题修改逻辑，开发者通过界面保存个性化配置后丢失的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I27CN8" target="_blank" rel="noopener">Gitee #I27CN8</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I2CBZQ" target="_blank" rel="noopener">Gitee #I2CBZQ</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I2978Y" target="_blank" rel="noopener">Gitee #I2978Y</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3IEXT" target="_blank" rel="noopener">Gitee #I3IEXT</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3Q0MO" target="_blank" rel="noopener">Gitee #I3Q0MO</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3QSAN" target="_blank" rel="noopener">Gitee #I3QSAN</a></p><p>9、针对接口分组中不存在API接口时出现链接点击空白的问题处理，如果分组下没有API接口,默认点击显示主页<a href="https://gitee.com/xiaoym/knife4j/issues/I2CVTF" target="_blank" rel="noopener">Gitee #I2CVTF</a></p><p>10、OpenAPI规范中tags缺失时导致接口不显示的问题优化,增加<code>default</code>默认分组<a href="https://gitee.com/xiaoym/knife4j/issues/I27M98" target="_blank" rel="noopener">Gitee #I27M98</a></p><p>11、针对服务端使用<code>@RequestMapping</code>注解通过<code>method</code>限定方法类型时，Ui增强功能过滤不生效的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I28RJ5" target="_blank" rel="noopener">Gitee #I28RJ5</a></p><p>12、文件上传类型接口请求数据显示类型错误的情况改进，根据参数设置接口请求数据类型为<code>multipart/form-data</code><a href="https://gitee.com/xiaoym/knife4j/issues/I29KMH" target="_blank" rel="noopener">Gitee #I29KMH</a></p><p>13、优化响应<code>html/xml/text</code>等内容时展现方式<a href="https://gitee.com/xiaoym/knife4j/issues/I2A0QA" target="_blank" rel="noopener">Gitee #I2A0QA</a></p><p>14、分组下拉框搜索失效的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I3BAOK" target="_blank" rel="noopener">Gitee #I3BAOK</a></p><p>15、优化OpenAPI版本判断的逻辑,根据响应OpenAPI规范JSON再判断获取当前的规范版本，防止出现空异常或Model不显示等问题<a href="https://gitee.com/xiaoym/knife4j/issues/I37X0Q" target="_blank" rel="noopener">Gitee #I37X0Q</a>、<a href="https://gitee.com/xiaoym/knife4j/issues/I3EMZE" target="_blank" rel="noopener">Gitee #I3EMZE</a></p><p>16、针对<code>JSON</code>请求格式的提交，增加<code>Beantify</code>按钮，可以对文本格式化美化的功能<a href="https://gitee.com/xiaoym/knife4j/issues/I39MUP" target="_blank" rel="noopener">Gitee #I39MUP</a></p><p><img loading="lazy" alt="image-20210507212527321" src="/assets/images/image-20210507212527321-359de18df782fcf429862b923aa78dbb.png" width="933" height="262" class="img_ev3q"></p><p>17、调试发送时增强<code>loading</code>效果体验<a href="https://gitee.com/xiaoym/knife4j/issues/I3BG5V" target="_blank" rel="noopener">Gitee #I3BG5V</a></p><p><img loading="lazy" alt="image-20210509083436452" src="/assets/images/image-20210509083436452-d5ae67f5541139e16f88cbe79c792732.png" width="925" height="379" class="img_ev3q"></p><p>18、SwaggerModels 内容太长不会自动换行的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I3QC02" target="_blank" rel="noopener">Gitee #I3QC02</a></p><p>19、针对Map属性的结构展示异常的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I37WB7" target="_blank" rel="noopener">Gitee #I37WB7</a></p><p>20、解决<code>afterScript</code>特性不能添加多个参数的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I3OJUW" target="_blank" rel="noopener">Gitee #I3OJUW</a></p><p>21、优化响应内容判断<code>base64</code>导致效率低下的问题<a href="https://gitee.com/xiaoym/knife4j/issues/I2VRD5" target="_blank" rel="noopener">Gitee #I2VRD5</a>。</p><p>22、针对增强注解<code>@ApiOperationSupport</code>提供的<code>ignoreParameters</code>属性提供正则模式的忽略策略支持<a href="https://gitee.com/xiaoym/knife4j/issues/I21ZKC" target="_blank" rel="noopener">Gitee #I21ZKC</a></p><h2 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="特点">特点<a class="hash-link" href="#特点" title="标题的直接链接">​</a></h2><ul><li>基于Vue+Ant Design构建的文档，更强大、清晰的接口文档说明能力以及接口调试能力</li><li>左右布局,基于Tabs组件的多文档查阅风格</li><li>支持在线导出Html、Markdown、Word、PDF等多种格式的离线文档</li><li>接口排序,支持分组及接口的排序功能</li><li>支持接口全局在线搜索功能</li><li>提供Swagger资源保护策略,保护文档安全</li><li>接口调试支持无限参数,开发者调试非常灵活，动态增加、删除参数</li><li>全局缓存调试信息,页面刷新后依然存在,方便开发者调试</li><li>以更人性化的table树组件展示Swagger Models功能</li><li>文档以多tab方式可显示多个接口文档</li><li>请求参数栏请求类型、是否必填着颜色区分</li><li>主页中粗略统计接口不同类型数量</li><li>支持自定义全局参数功能，主页包括header及query两种类型</li><li>JSR-303 annotations 注解的支持</li><li>更多个性化设置功能</li></ul><h2 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="界面">界面<a class="hash-link" href="#界面" title="标题的直接链接">​</a></h2><p>接口文档显示界面如下：</p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-5b76509501c86174096f8b795d2aba8455b.png" class="img_ev3q"></p><p>接口调试界面如下：</p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-995a784219ea035cacd428d15d04e9cbcb3.png" class="img_ev3q"></p><p>Swagger Models功能</p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-98e1dbdf35ab957f5c05df126f9bae44ffd.png" class="img_ev3q"></p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-d9a030b06b76f9a4935205df453af149788.png" class="img_ev3q"></p><p>支持导出离线Markdown、Html功能，markdown的表格较原先版本通过缩减显示为树形结构,<a href="https://doc.xiaominfo.com/html/knife4j-export-html.html">点击预览导出离线Html效果</a>，效果图如下：</p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-cfb2256485835e29a39f96eaaa60251e08c.png" class="img_ev3q"></p><p>通过第三方Markdown软件导出的PDF效果如下图:</p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-44bb80532b9767a33650e178809f612c3e7.png" class="img_ev3q"></p><p>同时提供了导出离线Html功能,Html功能界面风格和在线几乎没有区别,美观、大方、简洁,<a href="https://doc.xiaominfo.com/Knife4j-Offline-Html.html">点击在线预览效果</a>，</p><p>界面效果如下图：</p><p><img loading="lazy" src="https://oscimg.oschina.net/oscnet/up-4deb56c65774b4dc2ad54f5278f31e89a5d.png" class="img_ev3q"></p><h2 class="anchor anchorWithHideOnScrollNavbar_WYt5" id="其他">其他<a class="hash-link" href="#其他" title="标题的直接链接">​</a></h2><p>感谢各位朋友的支持,前往<a href="https://gitee.com/xiaoym/knife4j" target="_blank" rel="noopener">https://gitee.com/xiaoym/knife4j</a>点个Star吧~~ ：）</p></div><footer class="theme-doc-footer docusaurus-mt-lg"><div class="theme-doc-footer-edit-meta-row row"><div class="col"></div><div class="col lastUpdated_vwxv"><span class="theme-last-updated">最后<!-- -->由 <b>xiaoyumin</b> <!-- -->于 <b><time datetime="2022-08-14T10:05:39.000Z">2022年8月14日</time></b> <!-- -->更新</span></div></div></footer></article><nav class="pagination-nav docusaurus-mt-lg" aria-label="文档分页导航"><a class="pagination-nav__link pagination-nav__link--prev" href="/docs/changelog/x/4.1"><div class="pagination-nav__sublabel">上一页</div><div class="pagination-nav__label">v4.1.0版本-2023/03/23</div></a><a class="pagination-nav__link pagination-nav__link--next" href="/docs/changelog/x/2020-11-22-knife4j-2.0.8-issue"><div class="pagination-nav__sublabel">下一页</div><div class="pagination-nav__label">[v2.0.8-2020/11/22 Knife4j 2.0.8发布,轻量级微服务聚合文档中间件诞生]</div></a></nav></div></div><div class="col col--3"><div class="tableOfContents_bqdL thin-scrollbar theme-doc-toc-desktop"><ul class="table-of-contents table-of-contents__left-border"><li><a href="#日志" class="table-of-contents__link toc-highlight">日志</a><ul><li><a href="#openapi3" class="table-of-contents__link toc-highlight">OpenAPI3</a></li><li><a href="#聚合组件aggregation" class="table-of-contents__link toc-highlight">聚合组件aggregation</a></li><li><a href="#常规" class="table-of-contents__link toc-highlight">常规</a></li></ul></li><li><a href="#特点" class="table-of-contents__link toc-highlight">特点</a></li><li><a href="#界面" class="table-of-contents__link toc-highlight">界面</a></li><li><a href="#其他" class="table-of-contents__link toc-highlight">其他</a></li></ul></div></div></div></div></main></div></div><footer class="footer"><div class="container container-fluid"><div class="row footer__links"><div class="col footer__col"><div class="footer__title">文档指南</div><ul class="footer__items clean-list"><li class="footer__item"><a class="footer__link-item" href="/docs/quick-start">文档</a></li><li class="footer__item"><a class="footer__link-item" href="/docs/community/simple-demo">示例</a></li><li class="footer__item"><a class="footer__link-item" href="/docs/changelog">更新日志</a></li><li class="footer__item"><a class="footer__link-item" href="/docs/upgrading/upgrading-to-v4">升级到v4.0</a></li></ul></div><div class="col footer__col"><div class="footer__title">社区</div><ul class="footer__items clean-list"><li class="footer__item"><a href="https://gitter.im/knife4j/knife4j" target="_blank" rel="noopener noreferrer" class="footer__link-item">Gitter<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://www.oschina.net/question/tag/swagger-bootstrap-ui" target="_blank" rel="noopener noreferrer" class="footer__link-item">开源中国<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li></ul></div><div class="col footer__col"><div class="footer__title">关注公众号</div><ul class="footer__items clean-list"><li class="footer__item"><img src="/images/website/qrcode.jpg" width="150"></li></ul></div><div class="col footer__col"><div class="footer__title">更多</div><ul class="footer__items clean-list"><li class="footer__item"><a href="https://docusaurus.io" target="_blank" rel="noopener noreferrer" class="footer__link-item">Docusaurus<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://gitee.com/xiaoym/knife4j" target="_blank" rel="noopener noreferrer" class="footer__link-item">Gitee<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li><li class="footer__item"><a href="https://github.com/xiaoymin/swagger-bootstrap-ui" target="_blank" rel="noopener noreferrer" class="footer__link-item">GitHub<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_nPIU"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></li></ul></div></div><div class="footer__bottom text--center"><div class="footer__copyright">Apache License 2.0 | Copyright © 2018-2023-八一菜刀 浙ICP备18027673号-1 </div></div></div></footer></div>
<script src="/assets/js/runtime~main.e0db172c.js"></script>
<script src="/assets/js/main.c059fb6e.js"></script>
<!-- Google Tag Manager (noscript) -->
    <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-TKBX678" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
    <!-- End Google Tag Manager (noscript) --></body>
</html>